﻿<%@ Page Language="VB" AutoEventWireup="false" CodeFile="DisconnectedReasons.aspx.vb"
    Inherits="Reports_DisconnectedReasons" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
    Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
<%--<%@ Register assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" namespace="Microsoft.Reporting.WebForms" tagprefix="rsweb" %>
--%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>Disconnected Reasons Reports</title>
    <link type="text/css" href="css/redmond/jquery-ui-1.7.2.custom.css" rel="stylesheet" />
    <script type="text/javascript" src="js/jquery-1.3.2.min.js"></script>
    <script type="text/javascript" src="js/jquery-ui-1.7.2.custom.min.js"></script>
    <script type="text/javascript" src="js/Reports.js"></script>
    <link href="css/RollUp.css" rel="stylesheet" type="text/css" />
    <link href="../styles/acc.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
        .style1
        {
            width: 112px;
            height: 46px;
        }
        .style2
        {
            height: 46px;
        }
        .pushbutton
        {
            color: #b7b4a3;
        }
        .FgATTBlue
        {
        }
    </style>
</head>
<body style="font: normal 9pt Calabri, Arial, San-Serif;" bgcolor="">
    <form id="form1" runat="server">
    <%--   <p><h3>&nbsp;</h3><br /><%=DateTime.Today.ToString("MMMM yyyy") %> (<%=DateTime.Today.Day%> day of month)</p>--%>
    <div style="display: none">
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
    </div>
    <center>

        <div style="position: absolute; top: -56px; left: 5px;">
            <rsweb:ReportViewer ID="ReportViewer1" runat="server" Font-Names="Verdana" Font-Size="9pt"
                InteractiveDeviceInfos="(Collection)" WaitMessageFont-Names="Verdana" WaitMessageFont-Size="12pt"
                Width="100%" PageCountMode="Actual" ShowZoomControl="False" Style="margin-top: 75px">
                <LocalReport ReportPath="reports\SSRS\DisconnectedReasons.rdlc" EnableHyperlinks="True">
                </LocalReport>
            </rsweb:ReportViewer>
        </div>
        <asp:Panel ID="divRegions" runat="server" Style="position: absolute; top: 22px; right: 15px">
            <table cellpadding="0" cellspacing="0" style="border-collapse: collapse">
                <tr>
                    <td valign="top">
                        &nbsp;&nbsp;<asp:Label ID="Label2" runat="server" Text="From:" Font-Names="Segoe UI"
                            Font-Size="9pt" ForeColor="#999999" />
                    </td>
                    <td valign="top">
                        <asp:TextBox ID="txtFrom" runat="server" Font-Names="Segoe UI" Font-Size="9pt" ForeColor="#999999"
                            Height="20px" Width="68px"></asp:TextBox> <cc1:CalendarExtender ID="calStart" runat="server" TargetControlID="txtFrom">
        </cc1:CalendarExtender>
                    </td>
                    <td valign="top">
                        &nbsp;&nbsp;<asp:Label ID="Label3" runat="server" Text="To:" Font-Names="Segoe UI"
                            Font-Size="9pt" ForeColor="#999999" /><cc1:CalendarExtender ID="calEnd" runat="server" TargetControlID="txtTo">
        </cc1:CalendarExtender>
                    </td>
                    <td align="right" valign="top">
                        &nbsp;&nbsp;<asp:TextBox ID="txtTo" runat="server" Font-Names="Segoe UI" Font-Size="9pt"
                            ForeColor="#999999" Height="20px" Width="68px"></asp:TextBox>
                    </td>
                    <td valign="top">
                        <asp:CheckBoxList ID="chlProducts" runat="server" CellPadding="0" CellSpacing="1"
                            Style="margin-left: 4px; display: none" RepeatDirection="Horizontal" Font-Names="Segoe UI"
                            Font-Size="9pt" ForeColor="#999999" Height="20px">
                            <asp:ListItem Selected="True">HSIA</asp:ListItem>
                            <asp:ListItem Selected="True">IPTV</asp:ListItem>
                            <asp:ListItem Selected="True">VOIP</asp:ListItem>
                        </asp:CheckBoxList>
                    </td>
                    <td class="style2" valign="top">
                        &nbsp;&nbsp;<asp:Label ID="Label1" runat="server" Text="Market:" Font-Names="Segoe UI"
                            Font-Size="9pt" ForeColor="#999999"></asp:Label>
                    </td>
                    <td class="style1" valign="top">
                        <asp:DropDownList ID="ddlRegions" runat="server" AutoPostBack="True" Font-Names="Segoe UI"
                            DataSourceID="odsManagers" Font-Size="9pt" ForeColor="#999999" DataTextField="TXT"
                            DataValueField="VAL" AppendDataBoundItems="True">
                            <asp:ListItem Selected="True">Select a Region or Market</asp:ListItem>
                            <asp:ListItem>ALL REGIONS</asp:ListItem>
                            <%--                            <asp:ListItem Selected="True">Select...</asp:ListItem>
                            <asp:ListItem>ALL REGIONS</asp:ListItem>
                            <asp:ListItem>EAST</asp:ListItem>
                            <asp:ListItem>MIDWEST</asp:ListItem>
                            <asp:ListItem>SOUTHEAST</asp:ListItem>
                            <asp:ListItem>SOUTHWEST</asp:ListItem>
                            <asp:ListItem>WEST</asp:ListItem>--%>
                        </asp:DropDownList>
                        <img id="imgLoadingFirst" src="../images/LoadingProgressBar.gif" alt="Please wait..."
                            style="display: none;" />
                    </td>
                    <td valign="top">
                        <asp:ImageButton class="pushbutton" ID="imgbtnRefresh1" runat="server" ImageUrl="~/images/Refresh1.png"
                            Style="position: relative; bottom: 1px; left: 1px" ToolTip="Refresh Display" OnClick="imgbtnRefresh1_Click" />
                    </td>
                </tr>
            </table>
        </asp:Panel>
        <asp:Panel ID="Panel1" runat="server" class="FgOrangePale right" Style="font: 110% Webdings;
            width: 115px; position: absolute; top: -2px; right: 15px">
            <table cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="100%">
                <tr>
                    <td>
                        <asp:LinkButton class="pushbutton " ToolTip="First" ID="lnkbtnFirst" runat="server"
                            Text="9" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnPrev" runat="server" ToolTip="Previous"
                            Text="3" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnNext" runat="server" ToolTip="Next"
                            Text="4" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnLast" runat="server" ToolTip="Last"
                            Text=":" />
                    </td>
                    <td>
                        <img runat="server" id="imgNowDoing" src="~/images/led-blue.gif" alt="*" style="position: relative;
                            top: 2px" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnBack" ToolTip="Auto Previous" runat="server"
                            Text="7" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnPause" runat="server" ToolTip="Pause"
                            Text=";" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnForward" runat="server" ToolTip="Auto Next"
                            Text="8" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnStop" runat="server" ToolTip="Stop"
                            Text="<" />
                    </td>
                    <td>
                        <asp:TextBox ID="txtSpeed" Width="16px" runat="server" Font-Size="8pt" Text="30"
                            CssClass="FgATTBlue" BorderStyle="None" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnFaster" runat="server" ToolTip="Faster"
                            Text="6" />
                    </td>
                    <td>
                        <asp:LinkButton class="pushbutton" ID="lnkbtnSlower" runat="server" ToolTip="Slower"
                            Text="5" />
                    </td>
                </tr>
            </table>
        </asp:Panel>
     
        
    </center>

    <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ACC_NEW %>"
        SelectCommand="SELECT * FROM OUTS_BAN_MATCHED_VIEW WHERE REGION= LTRIM(SUBSTRING(@REGION,1, CHARINDEX(':', @REGION)-1)) AND END_DT BETWEEN @START_DATE AND @END_DATE">
        <SelectParameters>
            <asp:ControlParameter ControlID="ddlRegions" DefaultValue="%" Name="REGION" PropertyName="SelectedValue" />
            <asp:ControlParameter ControlID="txtFrom" DefaultValue="" Name="START_DATE" PropertyName="Text" />
            <asp:ControlParameter ControlID="txtTo" Name="END_DATE" PropertyName="Text" />
        </SelectParameters>
    </asp:SqlDataSource>
    <asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:ACC_NEW %>"
        SelectCommand="SELECT * FROM OUTS_BAN_MATCHED_VIEW WHERE SUBSTRING(@MARKET,1,9)=  SUBSTRING(MARKET,1,9) AND END_DT BETWEEN @START_DATE AND @END_DATE"
        ProviderName="System.Data.SqlClient">
        <SelectParameters>
            <asp:ControlParameter ControlID="ddlRegions" Name="MARKET" PropertyName="SelectedValue" />
            <asp:ControlParameter ControlID="txtFrom" DefaultValue="" Name="START_DATE" PropertyName="Text" />
            <asp:ControlParameter ControlID="txtTo" Name="END_DATE" PropertyName="Text" />
        </SelectParameters>
    </asp:SqlDataSource>
    <asp:SqlDataSource ID="SqlDataSource3" runat="server" ConnectionString="<%$ ConnectionStrings:ACC_NEW %>"
        SelectCommand="SELECT 'ALL REGIONS' AS REGION, 'ALL REGIONS' AS MARKET, ACCT_MGR, DISCONN_REASON, END_DT, PRODUCT, FEATURE, TRAC_ID, BAN, DAYS, [IN], OUT FROM OUTS_BAN_MATCHED_VIEW WHERE  (END_DT BETWEEN @START_DATE AND @END_DATE)"
        ProviderName="System.Data.SqlClient">
        <SelectParameters>
            <asp:ControlParameter ControlID="txtFrom" DefaultValue="" Name="START_DATE" PropertyName="Text" />
            <asp:ControlParameter ControlID="txtTo" Name="END_DATE" PropertyName="Text" />
        </SelectParameters>
    </asp:SqlDataSource>
    <asp:ObjectDataSource ID="odsManagers" runat="server" SelectMethod="dvACC_DATA" TypeName="Menus"
        OldValuesParameterFormatString="original_{0}">
        <SelectParameters>
            <asp:Parameter DefaultValue="Market" Name="psFirstLevelName" Type="String" />
        </SelectParameters>
    </asp:ObjectDataSource>
    </form>
</body>
</html>
